package com.ischoolbar.programmer.service.home.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ischoolbar.programmer.dao.home.AccountDao;
import com.ischoolbar.programmer.entity.home.Account;
import com.ischoolbar.programmer.service.home.AccountService;


@Service
public class AccountServiceImpl implements AccountService{

	@Autowired
	private AccountDao accountDao;
	
	@Override
	public Account findByUsername(String username) {
		// TODO Auto-generated method stub
		return accountDao.findByUsername(username);
	}

	@Override
	public int add(Account account) {
		// TODO Auto-generated method stub
		return accountDao.add(account);
	}
	
	@Override
	public int edit(Account account) {
		// TODO Auto-generated method stub
		return accountDao.edit(account);
	}
	
	@Override
	public int editPassword(Account account) {
		// TODO Auto-generated method stub
		return accountDao.editPassword(account);
	}

	@Override
	public List<Account> findList(Map<String, Object> queryMap) {
		// TODO Auto-generated method stub
		return accountDao.findList(queryMap);
	}

	@Override
	public int getTotal(Map<String, Object> queryMap) {
		// TODO Auto-generated method stub
		return accountDao.getTotal(queryMap);
	}

	@Override
	public int delete(String ids) {
		// TODO Auto-generated method stub
		return accountDao.delete(ids);
	}

	@Override
	public Account findById(Long id) {
		// TODO Auto-generated method stub
		return accountDao.findById(id);
	}

	
	
}
